home *** CD-ROM | disk | FTP | other *** search
/ Software Vault: The Gold Collection / Software Vault - The Gold Collection (American Databankers) (1993).ISO / cdr01 / halcn305.zip / TUTOR08.PAS < prev    next >
Pascal/Delphi Source File  |  1993-04-21  |  754b  |  30 lines

  1. program Tutor08;
  2. {$N+,E+}          {Required for floating point number handling}
  3. uses
  4.    CRT,
  5.    GSOB_DBF,
  6.    GSOB_VAR;
  7. var
  8.    MyFile  : GSO_dBaseFld;
  9.    MNum    : real;
  10. begin
  11.    ClrScr;
  12.    MNum := 0;
  13.    MyFile.Init('TUTOR1');
  14.    MyFile.Open;
  15.    MyFile.GetRec(Bttm_Record);
  16.    MyFile.NumberPut('PAYMENT',1234.56);
  17.    MyFile.PutRec(MyFile.RecNumber);
  18.    MyFile.GetRec(Top_Record);
  19.    while not MyFile.File_EOF do
  20.    begin
  21.       MNum := MNum + MyFile.NumberGet('PAYMENT');
  22.       writeln(MyFile.DelFlag:6,'  ',MyFile.RecNumber:4,'  ',
  23.               MyFile.FieldGet('LASTNAME'),'  ',
  24.               MyFile.FieldGet('PAYMENT'));
  25.       MyFile.GetRec(Next_Record);
  26.    end;
  27.    writeln('TOTAL':44,'  ',MNum:9:2);
  28.    MyFile.Close;
  29. end.
  30.